function index_add_submit (){
	var title = $("#index_add_title").val();
	var comdate = $("#index_add_date").val();
	var detail = $("#index_add_content").val();
	if(comdate == "" || title == "" ){
		$("#index_add_error").html("标题或日期不能为空!");
		return;
	}
	$.ajax({
		url : "system/addCompanyInfo.sls",
		type : "post",
		data : {"title":title,"comdate":comdate,"detail":detail},
		dataType : "json",
		success : function(result){
			if(result.status == 0){
				$("#index_add_error").html("添加成功!");
				setTimeout(function(){
					window.location.href="toSystem.sls";
				}, 1000);
			}
		},
		error : function (){
			window.location.href="error.sls";
		}
	});
}

